<template>
  <div id="app" :style="{height: windowheight,width:windowwidth}">
    <router-view></router-view>
  </div>
</template>

<script> 
export default {
  name: 'App',
  mounted() {
    this.$router.push({
      path:'/login'
    })
  },
  data() {
    return {
      
    }
  },
  computed:{
    windowheight(){
      return (window.innerHeight-50)+'px'
    },
    windowwidth(){
      return (window.innerWidth-30)+'px'
    }
  },
  methods:{
    // getData(){
    //   axios.get('http://localhost:8080/register').then(
    //     response =>{
    //       console.log('请求成功');
    //       this.$store.commit('getData',response.data)
    //     },
    //     error=>{
    //       console.log("请求失败",error.message);
    //     }
    //   )
    // },
    // postData(){
    //         var data = {"account":"1234123",
    //                     "name":"123123",
    //                     "email":"123123",
    //                     "password":"123123"
    //     }
    //         axios.post("/register",data).then(function (res) {
    //             var result = res.data
    //             console.log(result)
    //         })
    // }
  }
}
</script>

<style>
body {
    align-items: center;
    background-color: #e9e9e9;
    background: url(./Images/background.png);
    background-attachment: fixed;
    background-position: center;
    background-repeat: no-repeat;
    background-size: cover;
    display: grid;
    place-items: center;
}

</style>
